package com.bean;

import com.action.UserAction;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

@Configuration
public class ConfigBean {
    @Bean
    UserAction userAction(){
        System.out.println("默认名字是userAction");
        return new UserAction();
    }

    @Bean(value = "userAction1")
    UserAction userAction1(){
        System.out.println("自定义Bean名字为userAction1");
        return new UserAction();
    }
}
